﻿
namespace Gmantis.Imaging
{
    internal class ImageResizeFilterBox : ImageResizeFilter
    {
        protected override double GetRadius()
        {
            return 0.5;
        }

        protected override double GetWeight(double x)
        {
            if (x < 0.0)
            {
                x = -x;
            }
            if (x <= 0.5)
            {
                return 1.0;
            }
            return 0.0;
        }
    }
}
